.TH pkgstriptranslations 1 "December 17, 2004" "Martin Pitt"

.SH NAME

pkgstriptranslations \- extract translation files and remove gettext *.mo files from package build directories

.SH SYNOPSIS

.B pkgstriptranslations

.SH DESCRIPTION

.B pkgstriptranslations
extracts all gettext related files from the source and package build
directories and puts them into
.I <pkg\-build\-dir>/../package_version_arch_suffix.tar.gz\fR.
.I suffix
is configurable in
.I /etc/pkgbinarymangler/striptranslations.conf
and defaults to
.B translations\fR.

Tarball layout:

.TP
.B source/
contains all pot and po files from source package, preserving the directory structure.

.TP
.B debname1/, debname2/, ...
There will be one directory per generated binary deb package, each contains all .mo files from this deb, preserving directory structure.

.P
This script also removes all gettext
.I *.mo
files below
.I <pkg\-build\-dir>/usr/share/locale
from all built binary packages.
It will also remove subdirectories which became empty after removal of the
gettext files. However, if a file
.I /CurrentlyBuilding
is present (as on the Ubuntu autobuilders), then the
.I *.mo
files are only deleted if the Component: value in this file matches
one of the components configured in
.I /etc/pkgbinarymangler/striptranslations.conf\fR.
This allows to selectively strip files only for source packages which
are in e. g.
.B main
and
.B restricted\fR, but not in e. g.
.B universe\fR.

By default,
.B pkgstriptranslations
is inactive. To enable it, the
.B enable
option in the configuration file must be set to
.B true\fR.

.SH ENVIRONMENT VARIABLES

.TP
.B NO_PKG_MANGLE
If this variable is set to a nonempty value, then pkgstriptranslations
is disabled. This is most useful if source packages build nested binary
packages as part of their build.

.SH AUTHOR
.B pkgstriptranslations
is developed by Martin Pitt <martin.pitt@canonical.com>.
